<template>
  <!-- 主页 -->
  <div id="top">
    <!-- 用于3d地图 -->
    <div class="container">
      <!-- 添加 class 来控制 headerBar 的层级 -->
      <div class="header-wrapper">
        <headerBar />
      </div>
      <div class="body-container">
        <RouterView />
      </div>
    </div>
  </div>
</template>

<script setup>
import headerBar from "@/components/headerBar/index.vue";



</script>

<style scoped>
#top {
  width: 100%;
  height: 100vh;
}

.container {
  position: relative;
  width: 100%;
  height: 100%;
  background: url("@/assets/bg-g.gif") 0 0 no-repeat;
  background-size: 100% 100%;
  z-index: 1;
  overflow: hidden;
}

.container::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url("@/assets/home/homebg.png") 0 0 no-repeat;
  background-size: 100% 100%;
  z-index: 0;
  pointer-events: none;
}

/* 添加 header 包装器样式 */
.header-wrapper {
  position: relative;
  z-index: 2;
  /* 确保比地图和其他内容层级更高 */
}

.body-container {
  position: absolute;
  width: 100%;
}
</style>
